﻿using System;
using System.Collections.Generic;
using System.Text;

using Microsoft.Scripting;

namespace DlrBasic.Parser
{
    class Token
    {
        SourceSpan span;

        public SourceSpan Span
        {
            get { return span; }
        }

        TokenKind kind;

        public TokenKind Kind
        {
            get { return kind; }
        }

        string text;

        public string Text
        {
            get { return text; }
            set { text = value; }
        }

        int itemId;

        public int ItemId
        {
            get { return itemId; }
        }

        public Token(SourceSpan span, TokenKind kind, string text)
            : this(span, kind, text, 0)
        {
        }

        public Token(SourceSpan span, TokenKind kind, string text, int itemId)
        {
            this.span = span;
            this.kind = kind;
            this.text = text;
            this.itemId = itemId;
        }
    }
}
